package top.eggcode.system.modules.log.model;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import top.eggcode.common.base.BaseEntity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

/**
 * Title: 操作日志
 * Description: TODO
 * Date: 2021/5/25 14:59
 *
 * @author JiaQi Ding
 * @version 1.0
 */
@Data
@Table(name = "log_action")
@Entity
public class ActionLogEntity extends BaseEntity {

    @ApiModelProperty("用户名")
    private String username;

    @ApiModelProperty("网络路径")
    private String uri;

    @ApiModelProperty("操作名称")
    private String name;

    @ApiModelProperty("方法")
    @Column(columnDefinition = "LONGTEXT")
    private String method;

    @ApiModelProperty("参数列表")
    @Column(columnDefinition = "LONGTEXT")
    private String params;

    @ApiModelProperty("用时")
    private Long timeSpent;

    @ApiModelProperty("来源页面")
    private String referrer;

    @ApiModelProperty("会话令牌")
    private String sessionToken;

    @ApiModelProperty("用户代理")
    private String userAgent;

    @ApiModelProperty("服务器IP")
    private String host;

    @ApiModelProperty("响应值")
    @Column(columnDefinition = "LONGTEXT")
    private String result;

    @ApiModelProperty("方法地址")
    private String classMethod;

}
